package lab1;

import java.lang.reflect.InvocationTargetException;

public class FactoryProducer {
	static HouseAbstractFactory getFactory(String style) throws
			IllegalAccessException, ClassNotFoundException,
			NoSuchMethodException, InvocationTargetException {
		return (HouseAbstractFactory) Class.forName("lab1."+style+"Factory")
				.getDeclaredMethod("getInstance",null).invoke(null,null);
	}

}
